
package com.mediacloud.app.newsmodule.activity;

import android.os.Bundle;
import androidx.fragment.app.FragmentTransaction;

import com.eventTrack.TXExposureEvnet;
import com.mediacloud.app.model.activity.BaseBackActivity4NoDetail;
import com.mediacloud.app.newsmodule.R;
import com.mediacloud.app.newsmodule.adaptor.AdapterPreInflateHelper;
import com.mediacloud.app.newsmodule.fragment.recommend.RelatedListFragment;

public class RelatedListActivity extends BaseBackActivity4NoDetail {
    private RelatedListFragment fragment;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        AdapterPreInflateHelper.preSwitch = false;
        fragment = new RelatedListFragment();
        Bundle bundle = new Bundle();
        bundle.putParcelable("data", getIntent().getParcelableExtra("data"));
        bundle.putString("componentId", getIntent().getStringExtra("componentId"));
        bundle.putString("tipoff_catalogid", getIntent().getStringExtra("tipoff_catalogid"));
        bundle.putString("article_id", getIntent().getStringExtra("article_id"));
        bundle.putInt("type", getIntent().getIntExtra("type", 1));
        fragment.setArguments(bundle);
        FragmentTransaction transaction = getSupportFragmentManager().beginTransaction();
        transaction.replace(R.id.commentContent, fragment);
        transaction.show(fragment);
        transaction.commitNowAllowingStateLoss();
        setTitle("");

    }


    @Override
    public int getLayoutResID() {
        return R.layout.aappfactory_activity_comment;
    }

}